package sg.edu.nus.iss.vmcs.interfaces;

import org.eclipse.swt.widgets.Event;
import org.eclipse.swt.widgets.Listener;

public class VMCSCommandSWTAdapter implements Listener {
	
	private Command vmcsCommand;
	
	public VMCSCommandSWTAdapter(Command vmcsCommand) {
		this.vmcsCommand = vmcsCommand;
	}

	@Override
	public void handleEvent(Event evt) {
		System.out.println("I am SWT Adapter calling Command Interface");
		vmcsCommand.execute(evt.widget.getData("Value").toString());
	}
	
}
